MkShields
Container for Shields.io / GitHub badges.¶
Example: Regular¶
[![PyPI Latest Version](https://img.shields.io/pypi/v/mknodes.svg)](https://pypi.org/project/mknodes/)
[![Package status](https://img.shields.io/pypi/status/mknodes.svg)](https://pypi.org/project/mknodes/)
[![Package status](https://codecov.io/gh/phil65/mknodes/branch/main/graph/badge.svg)](https://codecov.io/gh/phil65/mknodes/)
<p><a href="https://pypi.org/project//"><img alt="PyPI Latest Version" src="https://img.shields.io/pypi/v/.svg"></a>
<a href="https://pypi.org/project//"><img alt="Package status" src="https://img.shields.io/pypi/status/.svg"></a>
<a href="https://codecov.io/gh///"><img alt="Package status" src="https://codecov.io/gh///branch/main/graph/badge.svg"></a></p>
MkShields
├── MkImage('https://img.shields.io/pypi/v/mknodes.svg', target='https://pypi.org/project/mknodes/', title='PyPI Latest Version')
├── MkImage('https://img.shields.io/pypi/status/mknodes.svg', target='https://pypi.org/project/mknodes/', title='Package status')
╰── MkImage('https://codecov.io/gh/phil65/mknodes/branch/main/graph/badge.svg', target='https://codecov.io/gh/phil65/mknodes/', title='Package status')
Example: Explicit¶
[![PyPI Latest Version](https://img.shields.io/pypi/v/mkdocs.svg)](https://pypi.org/project/mkdocs/)
[![Package status](https://img.shields.io/pypi/status/mkdocs.svg)](https://pypi.org/project/mkdocs/)
[![Package status](https://codecov.io/gh/mkdocs/mkdocs/branch/main/graph/badge.svg)](https://codecov.io/gh/mkdocs/mkdocs/)
<p><a href="https://pypi.org/project/mkdocs/"><img alt="PyPI Latest Version" src="https://img.shields.io/pypi/v/mkdocs.svg"></a>
<a href="https://pypi.org/project/mkdocs/"><img alt="Package status" src="https://img.shields.io/pypi/status/mkdocs.svg"></a>
<a href="https://codecov.io/gh/mkdocs/mkdocs/"><img alt="Package status" src="https://codecov.io/gh/mkdocs/mkdocs/branch/main/graph/badge.svg"></a></p>
MkShields
├── MkImage('https://img.shields.io/pypi/v/mkdocs.svg', target='https://pypi.org/project/mkdocs/', title='PyPI Latest Version')
├── MkImage('https://img.shields.io/pypi/status/mkdocs.svg', target='https://pypi.org/project/mkdocs/', title='Package status')
╰── MkImage('https://codecov.io/gh/mkdocs/mkdocs/branch/main/graph/badge.svg', target='https://codecov.io/gh/mkdocs/mkdocs/', title='Package status')
Name | Children | Inherits |
---|---|---|
MkContainer mknodes.basenodes.mkcontainer A node containing other MkNodes. |
graph TD
93860738873792["mkshields.MkShields"]
93860744077920["mkcontainer.MkContainer"]
93860744073616["mknode.MkNode"]
93860744080896["node.Node"]
140589822947552["builtins.object"]
93860744077920 --> 93860738873792
93860744073616 --> 93860744077920
93860744080896 --> 93860744073616
140589822947552 --> 93860744080896
/home/runner/work/mknodes/mknodes/mknodes/templatenodes/mkshields/metadata.toml
[metadata]
name = "MkShields"
icon = "simple-icons:shieldsdotio"
group = "badge"
virtual_children = true
[examples.regular]
title = "Regular"
jinja = """
{{ ["version", "status", "codecov"] | MkShields }}
"""
[examples.explicit]
title = "Explicit"
jinja = """
{{ ["version", "status", "codecov"] | MkShields(user="mkdocs", project="mkdocs") }}
"""
[output.markdown]
template = """
{{ node.items | join("\n") }}
"""
# {% for s in node.shields %}
# {{ s.image_url.format(user=node.user, project=node.project, branch=node.branch) | MkImage(target=s.get_url(user=node.user, project=node.project, title=node.title)) }}
# {% endfor %}